#include <iostream>
#include <utility/smart_ptr.h>
#include <utility/auto_ptr.h>
#include <utility/unique_ptr.h>
#include <utility/shared_ptr.h>
#include <utility/weak_ptr.h>
#include <test/a.h>
#include <test/b.h>

using namespace shijie::utility;
using namespace std;

class Test 
{
public:
	Test() = default;
	~Test() {
		cout << "Test is deleted" << endl;
	}

	void name(const string &name) {
		m_name = name;
	}

	string name() const {
		return m_name;
	}

private:
	string m_name;
};

int main() {
	SharedPtr<A> a(new A());
	SharedPtr<B> b(new B());

	cout << "a count: " << a.use_count() << endl;
	cout << "b count: " << b.use_count() << endl;

	// a->m_b = b;
	// b->m_a = a;
	
	// cout << "a count: " << a.use_count() << endl;
	// cout << "b count: " << b.use_count() << endl;
	return 0;
}